namespace IntConcept.Graph
{
using System.Collections.Generic;

public struct EdgeInfo
{
    public EdgeInfo(int t, int i)
    {
        id = i;
        to = t;
    }
    public int id,to;
}

public struct EdgeFullInfo
{
    public EdgeFullInfo(int f, int t,int i)
    {
        id = i;
        from = f;
        to = t;
    }
    public int id,from,to;
}

public interface IGraph
{
    int verticesCount {get;}
    int edgesCount {get;}
    int highestVertexId {get;}  //often verticesCount-1, but in dynamic graphs (with "holes" in numeration) it can be different
    int highestEdgeId {get;}
    IEnumerable<EdgeFullInfo> edges{get;}
    IEnumerable<int> vertices{get;}
    IEnumerable<EdgeInfo> outgoing(int v);
}

public interface IDynamicGraph: IGraph
{
    int add_vertex();
    int add_edge(int u, int v);
    void delete_vertex(int i);
    void delete_edge(int i);
    int[] reorganize(); //returns new indexes of vertices, maybe change to some PropetyMapper
}

}
